package com.ophiux.cs.domain.consultBase.model.entity;

import com.ophiux.utils.common.DateUtil;

public class Focus {
	private final static String FOCUS="1";
	private final static String CANCELFOCUS="2";
	/**
	 *
	 */
	private int ID;
	
	/**
	 *用户ID
	 */
	private String USER_ID;

	/**
	 *关注目标唯一ID  医生/医院ID
	 */
	private String TARGET_ID;

	/**
	 *目标类型  1:医生   2：医院
	 */
	private String TARGET_TYPE;

	/**
	 *操作类型  1：关注  2:取消关注
	 */
	private String IS_FOCUS;

	/**
	 *创建时间
	 */
	private String CREATE_TIME;

	/**
	 *修改时间
	 */
	private String RECENT_TIME;
	

	public Focus() {
		super();
	}

	public Focus(boolean iS_FOCUS,String uSER_ID, String tARGET_ID, String tARGET_TYPE) {
		super();
		isFocus(iS_FOCUS);
		USER_ID = uSER_ID;
		TARGET_ID = tARGET_ID;
		TARGET_TYPE = tARGET_TYPE;
		CREATE_TIME = DateUtil.getCurDateStr();
	}
	
	public void isFocus(boolean focus) {
		if(focus){
			this.IS_FOCUS=FOCUS;
		}else {
			this.IS_FOCUS=CANCELFOCUS;
		}
	}
	
	/**
	 * 关注
	 */
	public static Focus focus(Focus obj) {
		obj.setIS_FOCUS(FOCUS);
		obj.setCREATE_TIME(DateUtil.getCurDateStr());
		return obj;
	}
	/**
	 * 取消关注
	 * @param obj
	 * @return
	 */
	public static Focus cancelFocus(Focus obj) {
		obj.setIS_FOCUS(CANCELFOCUS);
		obj.setRECENT_TIME(DateUtil.getCurDateStr());
		return obj;
	}
	
	

	public int getID() {
		return ID;
	}

	public void setID(int iD) {
		ID = iD;
	}

	public String getTARGET_ID() {
		return TARGET_ID;
	}

	public void setTARGET_ID(String tARGET_ID) {
		TARGET_ID = tARGET_ID;
	}

	public String getTARGET_TYPE() {
		return TARGET_TYPE;
	}

	public void setTARGET_TYPE(String tARGET_TYPE) {
		TARGET_TYPE = tARGET_TYPE;
	}

	public String getIS_FOCUS() {
		return IS_FOCUS;
	}

	public void setIS_FOCUS(String iS_FOCUS) {
		IS_FOCUS = iS_FOCUS;
	}

	public String getCREATE_TIME() {
		return CREATE_TIME;
	}

	public void setCREATE_TIME(String cREATE_TIME) {
		CREATE_TIME = cREATE_TIME;
	}

	public String getRECENT_TIME() {
		return RECENT_TIME;
	}

	public void setRECENT_TIME(String rECENT_TIME) {
		RECENT_TIME = rECENT_TIME;
	}

	public String getUSER_ID() {
		return USER_ID;
	}

	public void setUSER_ID(String uSER_ID) {
		USER_ID = uSER_ID;
	}


}
